<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>局部组件</title>
    <script src="node_modules/vue/dist/vue.js"></script>
</head>
<body>
    <div id="app">
<!--  局部组件      -->
        <part-component1></part-component1>
        <part-component2></part-component2>
    </div>
    <div id="app2">
        <part-component1></part-component1>
    </div>
</body>
    <script>
        new Vue({
            el:"#app",
            data:{},
            methods:{},
            components:{
                "partComponent1":{
                    template:"<h1>这是第一个局部组件</h1>"
                },
                "partComponent2":{
                    template:"<h1>这是第二个局部组件</h1>"
                }

            }

        })

        new Vue({
            el:"#app2",

        })
    </script>
</html>